<!DOCTYPE html>
<html>
<#include "../../head.html">
    <body class="full">
    <div class="mc">
        <div>
            <div class="mc-l">
                <!--左侧导航---{-->
                <div id="navPanelContainer">
                    <div class="system-logo cd"></div>
                    <!--管理员信息---{-->
                    <#include "../../adminInfo.html">
                        <!--管理员信息---}-->
                        <div class="nav-wrap">
                            <#include "../left.html">
                        </div>
                </div>
                <!--左侧导航---}-->
            </div>
            <div class="mc-m">
                <div class="navToggle"></div>
            </div>
            <div class="mc-r">
                <!--顶部导航---{-->
                <#include "../../topNav.html">
                    <!--顶部导航---}-->

                    <!--面包屑导航---{-->
                    <#assign moduleName="新增温馨提示">
                        <#include "../banner.html">
                            <!--面包屑导航---}-->

                                <!--工具栏--{-->
                            <div id="toolbar" class="clearfix">
                                <div class="toolbor-module">
                                </div>
                            </div>
                                <!--工具栏--}-->

                                <div id="main" class="w750 clearfix">

                                    <form id="wForm" method="post" action="/admin/operate/addWarmPrompt.html" enctype="multipart/form-data" >
                                        <div class="valBox">
                                            <div class="top">
                                                <strong>新增温馨提示</strong>
                                            </div>
                                            <div class="clearfix">
                                                <ul class="title-v edit">
                                                    <li>
                                                        <div class="title">内容：</div>
                                                        <div class="v">
                                                           <textarea name="content" id="content" class="remark"></textarea>
                                                        </div>
                                                    </li>

                                                     <li>
                                                        <div class="title">链接地址：</div>
                                                        <div class="v s_writeInput">
                                                            <input type="text" name="link" id="link"  class="input_border" value="" size="30" />
                                                        </div>
                                                    </li>
                                                    <li>
                                                        <div class="title">过期时间：</div>
                                                        <div class="v s_writeInput">
                                                            <input class="input_border" style="width:150px;" name="expiryTime" id="expiryTime" value="" onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',onpicked:pickedFunc})"/>
                                                        </div>
                                                    </li>
                                                </ul>
                                            </div>
                                            <div id="bottomToolbar" class="clearfix">
                                                <input type="hidden"  name="actionType" value="add" />
                                                <input class="input-button" type="button"  id="subBtn" value="添加" style="margin-left: 180px;" />
                                            </div>
                                        </div>


                            </form>
                            </div>
            </div>
        </div>
        <div>
            <!--尾部--{-->
            <td colspan="3" class="mc-b"><#include "../../foot.html"></td>
            <!--尾部--}-->
        </div>
    </div>
	<script>
				$("#subBtn").click(function(){
					if($("#content").val()==''||$("#link").val()==''||$("#expiryTime").val()==''){
						alert('请填写必要信息！');
					}else{
						$("#wForm").submit();
					}
				});
				
				   function pickedFunc(){
                   	//二次审批时间节点计算
					    var expiryTime = $("#expiryTime").html();
				    	if(expiryTime != null && expiryTime != undefined && expiryTime != ""){
					    	var ss = expiryTime.split(" ");
					    	var approvalDate = new Date(Date.parse(ss[0]));
					    	approvalDate.setHours(0);
					    	approvalDate.setMinutes(0);
					    	approvalDate.setSeconds(0);
					    	
					    
					    	var y = $dp.cal.getP('y');
					    	var m = $dp.cal.getP('M');
					    	var d = $dp.cal.getP('d');
					    	var preDate = new Date(y,m-1,d,0,0,0);
					    	
					    
					    
				    	}
				    }
		</script>
    </body>
</html>

<#include "../../jsPage.html">
